<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Login extends CI_Controller {

	function __construct() {
   		parent::__construct();
 	}

 	function index() {
	 if($this->session->userdata('logged_in')) {
	   $session_data = $this->session->userdata('logged_in');
	   $data['ds_usuario'] = $session_data['ds_usuario'];
	   $this->load->view('home_view', $data);
	 } else {
   		$this->load->helper(array('form'));
	 	$this->load->view('login_view');
	 }
   		
 	}

}

?>
